package net.wicp.tams.common.connector;

import net.wicp.tams.common.connector.beans.CusDynaBean;
import net.wicp.tams.common.exception.IExcept;
import net.wicp.tams.common.exception.param.Response;

public abstract class BusiUtil {
	/**
	 * 设置返回值
	 * 
	 * @param outbean
	 *            返回bean
	 * @param error
	 *            错误信息
	 */
	public static void setResult(CusDynaBean outbean, IExcept error) {
		outbean.set(Response.errorCode, error.getErrorCode());
		outbean.set(Response.errorValue, error.getErrorValue());
		outbean.set(Response.errorDesc, error.getDesc());
		outbean.set(Response.errMsg, error.getErrMsg());
		outbean.set(Response.http, error.getHttp());
	}

}
